/*!
 * \file GapStateEchoPend.h
 * \brief State where heartbeat procedure is ongoing
 *
 */

#ifndef SGW_GAP_STATE_ECHO_PEND_H
#define SGW_GAP_STATE_ECHO_PEND_H

#include "GapStateBase.h"
#include "GapGenerator.h"

namespace tsc
{
namespace sgw
{

/**
 * Heartbeat procedure is ongoing, EchoReq has been send by SGW and it's
 * waiting for EchoResp.
 * Connection with MGW is established
 */
class GapStateEchoPend : public GapStateBase
{
public:

	static GapStateEchoPend* instance();

protected:

	virtual ~GapStateEchoPend();

    virtual void handleEventGapT8221Expired(
            GapGenerator* gapGen,
            GapEventT8221Expired* event,
            EventData*& eventData);

    virtual void handleEventGapEchoResponse(
            GapGenerator* gapGen,
            GapEventEchoResp* event,
            EventData*& eventData);

private:
    GapStateEchoPend();

};

} // namespace sgw
} // namespace tsc

#endif // SGW_GAP_STATE_ECHO_PEND_H
